(function(){

    
    alert('asdfasdf');


div = 'ajaxDiv';   
url2 = '/snapol/edit/ckeditor_plugins/snapol/dialogs/uploadDocument.php'; 

//url = url + "?q=" + document.getElementById('q').value;
//alert(div);

//url = "getAjax.snap?data="+document.getElementById(div).innerHTML;



//url2= "neuer_bilder_ordner";
alert(url2);


$.get(url2, function(data){

    //alert("Daten wurden gespeichert.");
    alert("Data Loaded2 from "+url2+": " + data);
    //newID = data;
    //document.getElementById('saveVideo').innerHTML = "Gespeichert";
    //document.getElementById('videoSearch').innerHTML = data;

//wieder aktivieren
//data = decodeURIComponent(data);
//alert("Data Loaded: " + data);
    //document.getElementById('saveVideo').innerHTML = "Gespeichert";
    //alert(document.getElementById(div).innerHTML);
    document.getElementById(div).style.visibility='visible';
    document.getElementById(div).innerHTML = data;   
    document.getElementById(div).style.position = 'absolute';
    
//alert(posX);
//alert(posY);

//alert(event.pageX);
    
    
    document.getElementById(div).style.left = posX+'px';
    document.getElementById(div).style.top = posY+'px';
    document.getElementById(div).style.backgroundColor = '#CCCCCC';
    
    
    // alert('asdf');
    
    
    var params = {  
        BGColor: "#F8F6E6"
    };
    
    var attributes = {  
        id: "MultiPowUpload",  
        name: "MultiPowUpload"
    };
    
    var flashvars = {
        formName : "upload",                
                     //savemultiuploadfile
        uploadUrl: "/saveMultiUploadFile?table=snapol_document&redirect=off&",
        //uploadUrl: "/",
      
      javaScriptEventsPrefix: "upload",
    //  uploadUrl: "/test.php",
    //  uploadButtonVisible: "No",
      useExternalInterface: "Yes",
      customListShowTextInput: false,
      labelUploadText: "Dateien zum hochladen...",
      backgroundColor: "#FFFFFF"
      
    };
   
   
    swfobject.embedSWF("/api/multiupload/ElementITMultiPowUpload2.swf", "upload", "450", "350", "9.0.0", "/api/multiupload/expressInstall.swf", flashvars, params, attributes);
   
 
});


}); 


   